<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<%
String id = (String)request.getParameter("id"); %>
<!DOCTYPE HTML>
<html>
<head>
<base href="${ctx }/">
<title>未结算订单详情</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<link rel="stylesheet"
	href="plugin/bootstrap-3.3.7-dist/css/bootstrap.min.css" />
<link rel="stylesheet" href="css/bootstrap-datetimepicker.css" />
<link rel="stylesheet"
	href="plugin/bootstrap-table/dist/bootstrap-table.css">
<!-- <link rel="stylesheet" href="css/zoom.css" media="all" />  -->
<link rel="stylesheet" href="alert/alert.css">
<style type="text/css">
a {
	color: #73879C;
}
#que>tr>td{
    width: 20%;
}

.form-group {
    margin-left: 10px;
    margin-top: 10px;
}
#oul>li{
list-style-type: none;
margin: 10px;
}
#tctable>tbody>tr>td{
    border: 1px solid #908787;
    padding: 18px;
}
</style>
</head>
<body>

	<div>
		<ul class="breadcrumb">
			<li><i class="icon-home home-icon"></i> <a
				href="javascript:void(0)"> Finance Management(财务管理)</a></li>
			<li class="active"><a href="view/finance/no_settlement_list.jsp">Unpaid Payout List(未结算订单列表)</a>
			</li>
			<li class="active"><a href="view/finance/no_settlement_details.jsp">Unpaid Payout Detail(未结算订单详情)</a>
			</li>
		</ul>
	</div>
	<br>
	<p id="onLineNum" style='text-align: center; color: red;'></p>
	<table id="demo-table"></table>
</body>

<!-- 加载需要的js -->
<script src="js/jquery-3.2.1.min.js"></script>
<script src="plugin/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script>
<script src="js/jquery-bootstrap-pagination.js"></script>
<script src="plugin/bootstrap-table/dist/bootstrap-table.min.js"></script>
<script
	src="plugin/bootstrap-table/dist/locale/bootstrap-table-zh-CN.min.js"></script>
<script src='alert/alert.js'></script>
<!--时间  -->
<script src="js/common.js"></script>
<script src="plugin/layer/layer.js"></script>
<script type="text/javascript" charset="utf-8">

    $(function () {
        initPath("${ctx }");
        initTable('demo-table', queryParams, columns, "orderItems/getNoSettlementDetail");
    });
   


    var columns = [{field: '', title: 'Serial Number',
        formatter: function (value, row, index) {
            return index+1;
        } },
        {
            field: 'orderNo',
            title: 'Order number(订单号)',
            align: 'center',
            valign: 'middle'
            },
        {
            field: 'carType',
            title: 'Service category(服务类型)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	var str="";
            	if(value==1){
            		str="fab ONE";
            	}else if(value==2){
            		str="fab";
            	}else{
            		str="fab PRO";
            	}
                  return str; }
        },
        {
            field: 'departureLocation',
            title: 'Pick up address(上传地址)',
            align: 'center',
            valign: 'middle',
        },
        {
            field: 'arrivedLocation',
            title: 'Destination address(下车地址)',
            align: 'center',
            valign: 'middle'
        },
        {
            field: 'startFee',
            title: 'Base Free(起步价)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	return value==null?"0":value;
            }
        },
        {
            field: 'tolls',
            title: 'Mileage(里程)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	var mileage=row.mileage==null?"0":row.mileage;
            	var mileageMoney=row.mileageMoney==null?"0":row.mileageMoney;
                  return "("+mileage+" KM ) "+mileageMoney+"AUD"; }
        },
        {
            field: 'upto',
            title: 'Min(时长)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	var time=row.time==null?"0":row.time;
            	var timeFee=row.timeFee==null?"0":row.timeFee;
                return "("+time+" Minutes) "+timeFee+"AUD"; }
        },  
        {
            field: 'serveiceCharge',
            title: 'Toll(过路费)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	return value==null?"0":value;
            }
        },
        {
            field: 'bookingFee',
            title: 'Booking Fee(预定费)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	return value==null?"0":value;
            }
        },
        {
            field: 'totals',
            title: 'Total(总额)',
            align: 'center',
            valign: 'middle',
            formatter: function (value, row, index) {
            	return value==null?"0":value;
            }
        }
    ];

    function queryParams(params) {
        var param = {
            pageNo: this.pageNumber,
            driverId:'<%=id%>',
            pageSize: this.pageSize
        }
        return param;
    }

    function queryParams1() {
        var param = {
        		 pageNo: 1,
                 driverId:'<%=id%>',
            pageSize: this.pageSize
        }
        return param;
    }

  
</script>
</html>


